package pkg

import (
	"fmt"
	"github.com/Baidu-AIP/golang-sdk/aip/censor"
	"github.com/Baidu-AIP/golang-sdk/util"
)

func Baidu() {
	client := censor.NewClient("btYupGZsG3pCa0srtcVELPlt", "fzTUONC01UZoVHktSexB4q6qUMaArD5J")
	base64d := util.ReadFileToBase64("图片路径")
	res := client.ImgCensor(base64d, nil)
	fmt.Println(res)
	//图片url
	res = client.ImgCensorUrl("图片url", nil)

}
